﻿<%@page import="java.util.*" %>
<%
	if(session.getAttribute("hotelId") == null || 
		session.getAttribute("userid") == null){
		response.sendRedirect("/index.jsp");
		return;
	}else if(session.getAttribute("workArea") == null ||
		session.getAttribute("counter") == null){
		response.sendRedirect("/choseworkarea.jsp");
		return;	
	}
%>
<!DOCTYPE html>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
<title>Admin Console | Company Info | Company Profile | Emm</title>
<%@page import="java.util.*" %>
<%
	String Code = (String)session.getAttribute("LanguageCode");
	String SubCode = (String)session.getAttribute("LanguageSubcode");
    Locale locale = new Locale(Code, SubCode);
	ResourceBundle resource = ResourceBundle.getBundle("resource", locale);
%>
<link href="/css/main.css" rel="stylesheet" />
<link href="/css/Adminconsole/Main.css" rel="stylesheet" />
<link href="/css/custom/jquery-ui-1.9.1.custom.min.css" rel="stylesheet" />
<link href="/css/Adminconsole/dialog.css" rel="stylesheet" />
<link href="/css/custom/loading.css" rel="stylesheet" />
<link href="/css/components/blocked/popup/popup.css" rel="stylesheet" />

<script src="/js/jquery-1.8.3.min.js"></script>
<script src="/js/jquery-ui-1.9.1.custom.min.js"></script>
<script src="/js/sharedData.js"></script>
<script src="/js/adminconsole/AdminShareData.js"></script>
<script src="/js/simpleservice.js"></script>
<script src="/js/loading.js"></script>
<script src="/js/adminconsole/CompanyInfo/hotelinfo.js"></script>
<script src="/js/adminconsole/CompanyInfo/countries2.js"></script>
<jsp:include page="/adminconsole/language.jsp" flush="true" />
</head>
<body>
	<header>
		<div class="brand">
			<div name="hotelName"><h2>iHotel</h2></div>
			<div name="pageName">Admin Console</div>
            	<jsp:include page="/adminconsole/menu.jsp" flush="true" />
		</div>
	</header>
	<div class="main">
		<div class="breadcrumb">
			<% out.print(resource.getString("AdminConsole.Page.HotelInfo"));%>
		</div>
        <div class="destitle"><% out.print(resource.getString("AdminConsole.Page.HotelInfo.suggest"));%></div>
		<div class="content">
			<table style="width:80%;border:none" cellpadding="5" cellspacing="0">
				<tr>
					<td style="text-align:right"><% out.print(resource.getString("AdminConsole.Page.CompanyProfile.companyname"));%>* </td>
					<td style="text-align:left">
						<input name="name" type="text" size="50" maxlength="200" id="name">
					</td>
				</tr>
				<tr>
					<td style="text-align:right"><% out.print(resource.getString("AdminConsole.Page.CompanyProfile.logo"));%></td>
					<td style="text-align:left">
						<input type="file" name="logo" id="logo">
						<em>(<% out.print(resource.getString("AdminConsole.Page.CompanyProfile.image"));%> 274pxX130px)</em><br>
						<input type="hidden" name="logoSaved" id="logoSavedId" value="complogo08042013072316661552744.jpeg">
					</td>
				</tr>
				<tr>
					<td style="text-align:right;vertical-align:top" valign="top"><% out.print(resource.getString("AdminConsole.Page.CompanyProfile.photo"));%></td>
					<td style="text-align:left">
						<input type="file" name="photo" id="photo">
						<em>(<% out.print(resource.getString("AdminConsole.Page.CompanyProfile.image"));%> 274pxX130px)</em>
					</td>
				</tr>
				<tr>
					<td style="text-align:right">
						<% out.print(resource.getString("AdminConsole.Page.CompanyProfile.line1"));%>* 
					</td>
					<td style="text-align:left">
						<input type="text" id="address" name="address" maxlength="500">
					</td>
				</tr> 
				<tr>
					<td style="text-align:right"><% out.print(resource.getString("AdminConsole.Page.CompanyProfile.line2"));%>* </td>
					<td style="text-align:left"><input type="text" id="address2" name="address2" maxlength="500" ></td>
				</tr>
				<tr>
					<td style="text-align:right"><% out.print(resource.getString("AdminConsole.Page.CompanyProfile.country"));%>*</td>
					<td style="text-align:left" valign="top"><select onChange="print_state('state',this.selectedIndex);" id="country" name="country"></select></td>
				</tr>
				<tr>
					<td style="text-align:right;vertical-align:top"><% out.print(resource.getString("AdminConsole.Page.CompanyProfile.state"));%>*</td>
					<td style="text-align:left;vertical-align:top">
						<select name ="state" id = "state"></select>
					</td>
				</tr>
				<tr>
					<td style="text-align:right"><% out.print(resource.getString("AdminConsole.Page.CompanyProfile.city"));%>*</td>
					<td style="text-align:left"><input name="city" maxlength="200" type="text" id="city"></td>
				</tr>
				<tr>
					<td align="right"><% out.print(resource.getString("AdminConsole.Page.CompanyProfile.zipcode"));%>*</td>
					<td style="text-align:left" valign="top"><input name="zipcode" maxlength="50" type="text" id="zipcode"></td>
				</tr>
				<tr>
					<td style="text-align:right"><% out.print(resource.getString("AdminConsole.Page.CompanyProfile.phone"));%>* </td>
					<td style="text-align:left"><input name="phone" maxlength="20" type="text" id="phone"></td>
				</tr>
				<tr>
					<td style="text-align:right"><% out.print(resource.getString("AdminConsole.Page.CompanyProfile.fax"));%></td>
					<td style="text-align:left"><input name="fax" maxlength="20" type="text" id="fax"></td>
				</tr>
				<tr>
					<td style="text-align:right"><% out.print(resource.getString("AdminConsole.Page.CompanyProfile.website"));%></td>
					<td style="text-align:left" valign="top"><input name="website" maxlength="100" type="text" size="50" id="website"></td>
				</tr>
				<tr>
					<td style="text-align:right"><% out.print(resource.getString("AdminConsole.Page.CompanyProfile.email"));%></td>
					<td style="text-align:left;vertical-align:top"><input id="email" maxlength="70" value="" type="text" ></td>
				</tr>
				<tr>
					<td style="text-align:right" valign="top"><% out.print(resource.getString("AdminConsole.Page.CompanyProfile.brief"));%></td>
					<td style="text-align:left"><textarea id="description" name="description" maxlength="500" cols="60" rows="6" ></textarea></td>
				</tr>
                <tr>
					<td style="text-align:right"><% out.print(resource.getString("AdminConsole.Page.CompanyProfile.roomamount"));%></td>
					<td style="text-align:left;vertical-align:top"><span id="roomamount">-</span></td>
				</tr>
				<tr>
					<td style="text-align:right" valign="top"><% out.print(resource.getString("AdminConsole.Page.CompanyProfile.offered"));%></td>
					<td style="text-align:left"><textarea id="offered" name="description" maxlength="500" cols="60" rows="6" ></textarea></td>
				</tr>
				<tr>
					<td style="height:20" colspan="2"></td>
				</tr>
				<tr style="vertical-align:middle">
					<td style="text-align:left;font-weight:bold" colspan="2"><% out.print(resource.getString("AdminConsole.Page.CompanyProfile.mainbill"));%> :</td>
				</tr>
				<tr>
					<td style="text-align:right;vertical-align:middle"><% out.print(resource.getString("AdminConsole.Page.CompanyProfile.same"));%></td>
					<td style="text-align:left;vertical-align:top"><input type="checkbox" id="sameaddress" name="sameaddress" value="1" onClick="copyAddress();"></td>
				</tr>
				<tr>
					<td style="text-align:right;vertical-align:middle"><% out.print(resource.getString("AdminConsole.Page.CompanyProfile.line1"));%>*</td>
					<td style="text-align:left;vertical-align:top"><input id="bAddress1" name="bAddress1" maxlength="500" type="text" size="35"></td>
				</tr>
				<tr>
					<td style="text-align:right;vertical-align:middle"><% out.print(resource.getString("AdminConsole.Page.CompanyProfile.line2"));%>*</td>
					<td style="text-align:left;vertical-align:top"><input id="bAddress2" name="bAddress2" maxlength="500" type="text" size="35"></td>
				</tr>
				<tr>
					<td style="text-align:right;vertical-align:middle"><% out.print(resource.getString("AdminConsole.Page.CompanyProfile.country"));%>*</td>
					<td style="text-align:left;vertical-align:top">
						<select onChange="print_state('state2',this.selectedIndex);" id="country2" name="country2"></select>
					</td>
				</tr>
				<tr>
					<td style="text-align:right;vertical-align:middle"><% out.print(resource.getString("AdminConsole.Page.CompanyProfile.state"));%>*</td>
					<td style="text-align:left;vertical-align:top">
						<select name ="state2" id = "state2"></select>
					</td>
				</tr>
				<tr>
					<td style="text-align:right;vertical-align:middle"><% out.print(resource.getString("AdminConsole.Page.CompanyProfile.city"));%>*</td>
					<td style="text-align:left;vertical-align:top"><input id="bCity" name="bCity" maxlength="200" type="text" ></td>
				</tr>
				<tr>
					<td style="text-align:right;vertical-align:middle"><% out.print(resource.getString("AdminConsole.Page.CompanyProfile.zipcode"));%>*</td>
					<td style="text-align:left;vertical-align:top"><input id="bZipcode" name="bZipcode" maxlength="50" type="text" ></td>
				</tr>
				<tr>
					<td style="text-align:right;vertical-align:middle"><% out.print(resource.getString("AdminConsole.Page.CompanyProfile.billPhone"));%>*</td>
					<td style="text-align:left;vertical-align:top"><input id="bPhone" name="bPhone" maxlength="50" type="text" ></td>
				</tr>
				<tr>
					<td style="text-align:right;vertical-align:middle"><% out.print(resource.getString("AdminConsole.Page.CompanyProfile.billFax"));%></td>
					<td style="text-align:left;vertical-align:top"><input id="bFax" name="bFax" maxlength="50" type="text" ></td>
				</tr>
				<tr>
					<td style="height:20" colspan="2">&nbsp;</td>
				</tr>
				<tr style="vertical-align:middle">
                      <td style="text-align:left;font-weight:bold" colspan="2"><% out.print(resource.getString("AdminConsole.Page.CompanyProfile.contact"));%> :</td>
				</tr>
				<tr>
					<td style="text-align:right;vertical-align:middle"><% out.print(resource.getString("AdminConsole.Page.CompanyProfile.cSal"));%>*</td>
					<td style="text-align:left;vertical-align:top"><select name="cSal" id="cSal" ></select></td>
				</tr>
				<tr>
					<td style="text-align:right;vertical-align:middle"><% out.print(resource.getString("AdminConsole.Page.CompanyProfile.cName"));%>*</td>
					<td style="text-align:left;vertical-align:top"><input id="cName" name="cName" maxlength="200" type="text" ></td>
				</tr>
				<tr>
					<td style="text-align:right;vertical-align:middle"><% out.print(resource.getString("AdminConsole.Page.CompanyProfile.cLastName"));%>*</td>
					<td style="text-align:left;vertical-align:top"><input id="cLastname" name="cLastname" maxlength="200" type="text" ></td>
				</tr>
				<tr>
					<td style="text-align:right;vertical-align:middle"><% out.print(resource.getString("AdminConsole.Page.CompanyProfile.cDesignation"));%>*</td>
					<td style="text-align:left;vertical-align:top"><input id="cDesign" name="cDesign" maxlength="200" type="text" ></td>
				</tr>
				<tr>
					<td style="text-align:right;vertical-align:middle"><% out.print(resource.getString("AdminConsole.Page.CompanyProfile.billPhone"));%>*</td>
					<td style="text-align:left;vertical-align:top">
						<input id="cPhone" name="cPhone" maxlength="20" type="text" >
                        &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<% out.print(resource.getString("AdminConsole.Page.CompanyProfile.extn"));%>#
                        <input id="cExtn" name="cExtn" maxlength="20" type="text" value="" size="5">
					</td>
				</tr>
				<tr>
					<td style="text-align:right;vertical-align:middle"><% out.print(resource.getString("AdminConsole.Page.CompanyProfile.billFax"));%></td>
					<td style="text-align:left;vertical-align:top"><input id="cFax" name="cFax" maxlength="20" type="text" ></td>
				</tr>
				<tr>
					<td style="text-align:right;vertical-align:middle"><% out.print(resource.getString("AdminConsole.Page.CompanyProfile.cEmail"));%>*</td>
					<td style="text-align:left;vertical-align:top"><input id="cEmail" name="cEmail" maxlength="100" type="text" size="35"></td>
				</tr>
				<tr>
					<td style="text-align:right;vertical-align:middle"><% out.print(resource.getString("AdminConsole.Page.CompanyProfile.cMobile"));%></td>
					<td style="text-align:left;vertical-align:top"><input id="cMobile" name="cMobile" maxlength="20" value="" type="text" ></td>
				</tr>
				<tr>
					<td style="text-align:right">&nbsp;</td>
					<td style="text-align:left"><% out.print(resource.getString("AdminConsole.Page.CompanyProfile.note"));%></td>
				</tr>
				<tr>
					<td style="text-align:right">&nbsp;</td>
					<td style="text-align:left"><input type="button" value="<% out.print(resource.getString("AdminConsole.Page.center.save"));%>" onClick="saveCompanyInfo()">
						<input type="button" value="<% out.print(resource.getString("AdminConsole.Page.center.cancel"));%>">
					</td>
				</tr>
			</table>
<script>
	loadSal();
	print_country("country");
	print_country("country2");
	var t1 = $("#country")[0].selectedIndex;
	var t2 = $("#country2")[0].selectedIndex;
	print_state("state",t1);
	print_state("state2",t2);
	edithotelinfo();
</script>
		</div>
	</div>

	<div id="BlankDialog" style="display:none; padding:5px 0 0 10px;"></div>
	<div id="loadingScreen"></div>
	<div name="dynamic" style="display:none"></div>
</body>

</html>